﻿Imports NHibernate
Imports NHibernate.Criterion
Imports TodoMicroSolutionPackV1.dal.dto

Namespace dal.dao
    Public Class puntoVentaDAO
        Inherits GenericNHibernateDAO(Of puntoVentaDAO, Integer)
        Public Sub New(ByRef session As ISession)
            Me.session = session
        End Sub
        Public Function getPuntosDeVentaPorEmpresa(ByRef empresa As empresa) As IList(Of puntoVenta)
            Dim criteria As ICriteria = session.CreateCriteria(Of puntoVenta)()
            criteria.Add(Expression.Eq("empresa", empresa))

            Return criteria.List(Of puntoVenta)()
        End Function
    End Class
End Namespace

